<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@include file="/context/mytags.jsp"%>
<t:base type="jquery,easyui,tools,DatePicker"></t:base>
<div id="main_depart_list" class="easyui-layout" fit="true">
  <div region="center" style="padding:1px;">
  <t:datagrid name="tSNoticeList" checkbox="true" fitColumns="false" title="薪资发放申请管理" actionUrl="salaryPayRollReqMgrController.do?datagrid2" idField="id" fit="true" queryMode="group">
   <t:dgCol title="ID"  field="id"  hidden="true"  queryMode="group"  width="120"></t:dgCol>
   <t:dgCol title="申请编号"  field="applyNo"  hidden="false"  queryMode="group"  width="120"></t:dgCol>
   <t:dgCol title="申请人"  field="createBy"  hidden="false"  queryMode="group"  width="320"></t:dgCol>
   <t:dgCol title="发放时间"  field="payDate"  hidden="false"  queryMode="group"  width="220"></t:dgCol>
   <t:dgCol title="申请时间"  field="createDate"  hidden="false"  queryMode="group"  width="220"></t:dgCol>
   <t:dgCol title="申请状态"  field="status"  hidden="false"  replace="待审核_1,已审核通过_2,已发放_3,审核不通过_4" queryMode="group"  width="520"></t:dgCol>


   <t:dgCol title="common.operation" field="opt" width="120"></t:dgCol>
<%--     <t:dgFunOpt funname="userListbyrole(id,applyNo)" title="申请详情" urlclass="ace_button"  urlfont="fa-user"></t:dgFunOpt> --%>
	<t:dgDefOpt title="发放" exp="status#eq#2"   url="salaryPayRollReqMgrController.do?doPayed&id={id}" urlclass="ace_button"  urlfont="fa-trash-o"/>
   	<t:dgDelOpt title="通过"   exp="status#eq#1" url="salaryPayRollReqMgrController.do?doPassAduit&id={id}" urlclass="ace_button"  urlfont="fa-trash-o"/>
   
<%--    <t:dgFunOpt title="通过" url="salaryPayRollReqMgrController.do?doPassAduit&id={id}" urlclass="ace_button"  urlfont="fa-trash-o"/> --%>
   	<t:dgDelOpt title="不通过"  exp="status#eq#1" url="salaryPayRollReqMgrController.do?doNoPassAduit&id={id}" urlclass="ace_button"  urlfont="fa-trash-o"/>
<%--    <t:dgToolBar title="common.add" icon="icon-add" url="salaryPayRollReqMgrController.do?goAdd" funname="add" width="800" height="600"></t:dgToolBar> --%>
<%--    <t:dgToolBar title="common.edit" icon="icon-edit" url="salaryPayRollReqMgrController.do?goUpdate" funname="update" width="800" height="600"></t:dgToolBar> --%>
<%--    <t:dgToolBar title="common.batchDelete"  icon="icon-remove" url="salaryPayRollReqMgrController.do?doBatchDel" funname="deleteALLSelect"></t:dgToolBar> --%>
  <%-- <t:dgFunOpt exp="noticeLevel#eq#2" funname="queryRoles(id)" title="common.authority" urlclass="ace_button"  urlfont="fa-toggle-on"></t:dgFunOpt>
   <t:dgFunOpt exp="noticeLevel#eq#3" funname="queryUsers(id)" title="common.authority" urlclass="ace_button"  urlfont="fa-toggle-on"></t:dgFunOpt>--%>
  </t:datagrid>
  </div>
 </div>
 <div region="east" style=" display:none;" split="true">
<div tools="#tt" class="easyui-panel" title='申请详情' style="padding: 10px;" 
fit="true" border="false" id="function-panel">
</div>
</div>
 <div id="tt"></div>
</div>
  

 <script type="text/javascript">
 $('#function-panel').hide();
 function userListbyrole(id,applyNo) {
		$("#function-panel").panel(
			{
				title :'申请编号:' + applyNo,
				href:"salaryPayRollReqMgrController.do?employeeApplyDetail&applyId=" + id
			}
		);
		$('#function-panel').panel("refresh" );
		
	}

 
 
 function passaudit(id){
		if(li_east == 0){
			   $('#main_depart_list').layout('expand','east'); 
			}
			$('#subListpanel').panel("refresh", "salaryPayRollReqMgrController.do?doPassAduit&id==" + id);
	}
 
 
 function queryRoles(id){
		if(li_east == 0){
			   $('#main_depart_list').layout('expand','east'); 
			}
			$('#subListpanel').panel("refresh", "noticeAuthorityRoleController.do?noticeAuthorityRole&noticeId=" + id);
	}
 function queryUsers(id){
		if(li_east == 0){
			   $('#main_depart_list').layout('expand','east'); 
			}
			$('#subListpanel').panel("refresh", "noticeAuthorityUserController.do?noticeAuthorityUser&noticeId=" + id);
	}
 </script>
